package javaeSE.fanxingTest1;

import org.junit.Test;

import java.util.Iterator;
import java.util.List;

public class DAOTest {

    @Test
    public void test1(){
        CustomerDAO dao1 = new CustomerDAO();
        Customer customer1 = new Customer();
        dao1.add(customer1);

        List<Customer> list = dao1.getForList();

        Iterator<Customer> iterator = list.iterator();

        while(iterator.hasNext()){
            Customer customer = iterator.next();
            System.out.println(customer);
        }


        // StudentDAO dao2 = new StudentDAO();
        // Student student = dao2.getIndex(1);
    }
}
